#!/usr/bin/env bash
# encoding: utf-8.0

function test_split_func()
{
  local params="$1"
  #echo "params:${params}"
  IFS=:
  to_array=()
  i=0
  for dir in $params
  do
    to_array[$i]=${dir}
    i+=1
  done

  echo ${to_array[*]}
}

#test_split_func $LD_LIBRARY_PATH

result=($(test_split_func $LD_LIBRARY_PATH))

echo "func return: ${result[*]}"

